import java.util.Arrays;
import java.util.Scanner;

/**
 * 【程序15】   
 * 题目：输入三个整数x,y,z，请把这三个数由小到大输出。 
 */
public class test15 {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int[] array = new int[3];
        System.out.print("请输入整数x：");
        array[0] = sc.nextInt();
        System.out.print("请输入整数y：");
        array[1] = sc.nextInt();
        System.out.print("请输入整数z：");
        array[2] = sc.nextInt();
        int a;
        if (array[0] > array[1]) {
            a = array[0];
            array[0] = array[1];
            array[1] = a;
            if (array[2] <= array[0]) {
                a = array[2];
                array[2] = array[1];
                array[1] = array[0];
                array[0] = a;
                System.out.println(Arrays.toString(array));
            } else if (array[2] > array[0] && array[2] <= array[1]) {
                a = array[1];
                array[1] = array[2];
                array[2] = a;
                System.out.println(Arrays.toString(array));
            } else {
                System.out.println(Arrays.toString(array));
            }
        } else {
            if (array[2] <= array[0]) {
                a = array[2];
                array[2] = array[1];
                array[1] = array[0];
                array[0] = a;
                System.out.println(Arrays.toString(array));
            } else if (array[2] > array[0] && array[2] <= array[1]) {
                a = array[1];
                array[1] = array[2];
                array[2] = a;
                System.out.println(Arrays.toString(array));
            } else {
                System.out.println(Arrays.toString(array));
            }
        }
    }
}
